package com.superatom.designpattern.decorator;

/**
 * 测试类
 */
public class DecoratorV2Test {
    public static void main(String[] args) {
        ABatterCake aBattercake;
        aBattercake = new BatterCake();
        aBattercake = new EggDecorator(aBattercake);
        aBattercake = new EggDecorator(aBattercake);
        aBattercake = new SausageDecorator(aBattercake);

        System.out.println(aBattercake.getDesc()+" 销售价格:"+aBattercake.cost());
    }
}
